import { createRouter, createWebHistory } from 'vue-router'
import Home from '../views/Home.vue'

const routes = [
  {
    path: '/',
    redirect: '/index'
  },
  {
    path: '/index',
    name: 'Index',
    component: Home 
  },
  {
    path: '/home',
    name: 'Home',
    component: () => import('../views/Navigation.vue')
  },
  {
    path: '/board',
    name: 'Board',
    component: () => import('../views/Board.vue')
  },
  {
    path: '/messageEditor',
    name: 'MessageEditor',
    component: () => import('../views/MessageEditor.vue')
  }
]

export default createRouter({
  history: createWebHistory(),
  routes
})